package com.example.p103;

import java.net.HttpURLConnection;
import java.net.URL;

/**
 * @author Lenovo
 */
public class Main {
    public static void main(String args[])throws Exception {
        URL url = new URL("http://www.runoob.com");
        HttpURLConnection httpCon =
                (HttpURLConnection) url.openConnection();
        long date = httpCon.getDate();
        if ( date == 0)
            System.out.println("无法获取日期信息。");
        else
            System.out.println("文件最后修改时间：" + date);

    }
}
